/* 
 * Copyright (C)2008 Vladimir Hozjan vladimir.hozjan@gmail.com
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA 
 */

/**
 * @file  tetrisElement.h
 *
 * TetrisElement class declaration
 *
 * @author Vladimir Hozjan
 * @date   26.12.2008 
 *
 * @remarks VHOZ [26.12.2008]: Class created
 */
#ifndef _tetrisElement_h_
#define _tetrisElement_h_

#include "tetrisMatrix.h"

/**
 * @class TetrisElement
 *
 * Tetris element contains single element. Elements is put
 * in matrix with size dimension x dimension.
 *
 * @author VHOZ
 *
 * @remarks VHOZ [26.12.2008]: Class created
 */
class TetrisElement : public TetrisMatrix {
public:
  /// Constructor
  TetrisElement(unsigned short aElementId, unsigned short aDimension, const unsigned short **aCells);

  /// Copy constructor
  TetrisElement(TetrisElement const &);

  /// Destructor
  ~TetrisElement();

  /// Rotate element left
  void rotateElementLeft();

  /// Rotate element right
  void rotateElementRight();

  /// Return dimension of element
  unsigned short getDimension() const;

  /// Get element id
  unsigned short geElementId() const {return mElementId;};
protected:
private:
  /// Constructor
  TetrisElement();

  unsigned short mElementId;
};

#endif // tetrisElement_h__
